function handleMergeObj(){
    let newObj = {};
    let objArr = [];
    let removeAttrArr = []
    for(let i=0;i<arguments.length; i++){
        if(arguments[i] instanceof Array){
            removeAttrArr = arguments[i];
            break;
        }
        objArr.push(arguments[i]);
    }
    // console.log('removeAttrArr-->', removeAttrArr.includes())
    for(let i=0; i<objArr.length; i++){
        let obj = objArr[i]
        for(let key in obj){
            if(!removeAttrArr.includes(key)){
                newObj[key] = obj[key];
            }
        }
    }

    return newObj;
}

module.exports = handleMergeObj;